CREATE EXTERNAL TABLE jms_ods.tab_barscan_transfer_mail (
RECORDID string COMMENT '记录编号',
BILLCODE string COMMENT '运单编号',
SCANTYPE string COMMENT '扫描类型',
SCANUSER string COMMENT '扫描雇员',
INPUTSITE string COMMENT '录入部门',
SCANTIME timestamp COMMENT '扫描时间',
INPUTTIME timestamp COMMENT '录入时间',
operatedate timestamp COMMENT '操作日期',
SEND_DELIVER_USER string COMMENT '派件或收件员',
VILLAGEFLAG bigint COMMENT '进村件标识 0 否 1 是',
TRANSFERFLAG bigint COMMENT '转邮标识 1 菜鸟 2 邮政',
REMARK string COMMENT '备注',
MODIFYUSER string COMMENT '修改人',
MODIFYTIME timestamp COMMENT '修改时间',
MOBILE string COMMENT '手机号码',
PISTOLID string COMMENT '巴枪ID',
REMARK1 string COMMENT '备注1',
REMARK2 string COMMENT '备注2',
SCANSITECODE string COMMENT '扫描网点编号',
UPLOADTIME timestamp COMMENT '上传时间',
REMARK3 string COMMENT '备注3',
SCANUSERCODE string COMMENT '扫描雇员编号',
SEND_DELIVER_USERCODE string COMMENT '收派员编号',
SOURCE string COMMENT '来源',
REMARK5 string COMMENT '备注5',
REMARK6 bigint COMMENT '备注6',
REMARK4 string COMMENT '备注4',
SCANSITEID bigint COMMENT '扫描网点ID',
SCANUSERID bigint COMMENT '扫描雇员ID',
SEND_DELIVER_USERID bigint COMMENT '收派员ID'
) comment '转邮扫描'
PARTITIONED BY (dt STRING COMMENT '时间分区')
STORED AS PARQUET
LOCATION '/dw/hive/jms_ods.db/external/tab_barscan_transfer_mail'
TBLPROPERTIES (
    'discover.partitions' = 'false',
    'parquet.column.index.access' = 'true'
);
